package com.zyh.stream;

import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;

/**
 * @Author zyh
 * @Date 2024/8/5 14:17
 * @Description 中文乱码问题
 */

public class StreamDemo3 {
    public static void main(String[] args) throws IOException {
        FileInputStream fis = new FileInputStream("D:\\course\\02-JavaSE进阶\\day09-IO流\\素材\\180-作业2.avi");
        FileOutputStream fos = new FileOutputStream("D:\\course\\02-JavaSE进阶\\day09-IO流\\素材\\b\\200-注意事项.avi");
        byte[] car = new byte[1024];
        int len = -1;
        while ((len = fis.read(car)) != -1) {
            fos.write(car, 0, len);
        }
        fos.close();
        fis.close();
    }
}
